package com.example.androiduidemo2.widget;

import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.widget.ImageView;
import android.widget.RelativeLayout;
import android.widget.TextView;

import com.example.androiduidemo2.R;


public class EmptyView extends RelativeLayout {

   private TextView mTvEmptyMessage;
   private ImageView mIvEmptyIcon;

   public EmptyView(Context context) {
      super(context);
      initView();
   }

   public EmptyView(Context context, AttributeSet attrs) {
      super(context, attrs);
      initView();
   }

   private void initView() {
      LayoutInflater.from(getContext()).inflate(R.layout.empty_view, this, true);
      mTvEmptyMessage = findViewById(R.id.empty_message);
      mIvEmptyIcon = findViewById(R.id.empty_icon);
   }
}
